<?php


/*
 * Premium
 */

Router::addRoute('buyPremium', 'premium', array('controller'=>'UserController', 'method'=>'Premium'));

/*
 * rejestracja
 */
Router::addRoute('sendConfirmationEmail', 'sign-in-confirmation', array('controller'=>'AuthController', 'method'=>'SendConfirmationEmail'));
Router::addRoute('fbSignInValidation', 'fb-sign-in,validation', array('controller'=>'AuthController', 'method'=>'FbRegisterValidation', 'config' => array('render' => 'validator')));
Router::addRoute('signInValidation', 'sign-in,validation', array('controller'=>'AuthController', 'method'=>'RegisterValidation', 'config' => array('render' => 'validator')));
Router::addRoute('logInValidation', 'login,validation', array('controller'=>'AuthController', 'method'=>'LoginValidation', 'config' => array('render' => 'validator')));
Router::addRoute('fbVerify', 'facebook/verify', array('controller'=>'AuthController', 'method'=>'FbVerify'));
Router::addRoute('fbRegister', 'facebook/sign-in', array('controller'=>'AuthController', 'method'=>'FbRegister'));
Router::addRoute('logIn', 'login', array('controller'=>'AuthController', 'method'=>'Login'));
Router::addRoute('signIn', 'sign-in', array('controller'=>'AuthController', 'method'=>'Register'));
Router::addRoute('confirmAccount', 'confirmation/:hash', array('controller'=>'AuthController', 'method'=>'ConfirmAccount'));
Router::AddRoute('ajaxCheckEmail','checkemail',array('controller' => 'AuthController','method' => 'AjaxCheckEmail', 'config' => array('render' => 'ajax')));


Router::AddRoute('authRemindPassword','remind-password',array('controller' => 'AuthController', 'method' => 'RemindPassword'));
Router::AddRoute('authValidateRemindPassword','validate-remind-password',array('controller' => 'AuthController', 'method' => 'ValidateRemindPassword', 'config' => array('render' => 'validator')));
/*
 * quiz po rejestracji
 */
Router::AddRoute('registrationQuizStep1','profile-quiz,step1',array('controller' => 'QuizController', 'method' => 'RegistrationQuizStep1'));
Router::AddRoute('registrationQuizStep2','profile-quiz,step2',array('controller' => 'QuizController', 'method' => 'RegistrationQuizStep2'));
Router::AddRoute('registrationQuizStep3','profile-quiz,step3',array('controller' => 'QuizController', 'method' => 'RegistrationQuizStep3'));
Router::AddRoute('registrationQuizFinal','profile-quiz,final',array('controller' => 'QuizController', 'method' => 'RegistrationQuizFinal'));
Router::AddRoute('AjaxRacquetFinder','racquet-finder',array('controller' => 'ProductController', 'method' => 'AjaxRacquetFinder'));
Router::AddRoute('quizQuickRocketFinderResultsSort','quick-rocket-finder-results/page/:page/t/:t/v/:v/o/:o',array('controller' => 'QuizController', 'method' => 'QuickRocketFinderResults'));
Router::AddRoute('quizQuickRocketFinderResults','quick-rocket-finder-results',array('controller' => 'QuizController', 'method' => 'QuickRocketFinderResults'));
Router::AddRoute('quizQuickRocketFinder','quick-rocket-finder',array('controller' => 'QuizController', 'method' => 'QuickRocketFinder'));



/*
 * user
 */
Router::addRoute('ajaxRateGallery', 'ajax/rate/gallery/:idGallery/:like', array('controller'=>'UserController', 'method'=>'AjaxRateGallery'));
Router::addRoute('ajaxRateVideo', 'ajax/rate/video/:idGallery/:like', array('controller'=>'UserController', 'method'=>'AjaxRateVideo'));
Router::addRoute('userAddGallery', 'user/addgallery', array('controller'=>'UserController', 'method'=>'AddGallery'));
Router::addRoute('userAddVideo', 'user/addvideo', array('controller'=>'UserController', 'method'=>'AddVideo'));
Router::addRoute('userGalleryPage', 'user/gallery/:idGallery/:page', array('controller'=>'UserController', 'method'=>'GalleryView'));
Router::addRoute('userGallery', 'user/gallery/:idGallery', array('controller'=>'UserController', 'method'=>'GalleryView'));
Router::addRoute('userVideo', 'user/video/:idGallery', array('controller'=>'UserController', 'method'=>'VideoView'));

Router::addRoute('userGalleries', 'user/galleries/:idUser', array('controller'=>'UserController', 'method'=>'Galleries'));
Router::addRoute('userVideos', 'user/videos/:idUser', array('controller'=>'UserController', 'method'=>'Videos'));

Router::addRoute('userAddToMyEq', 'user/ajaxAddToEq/:idProduct', array('controller'=>'UserController', 'method'=>'ajaxAddToEq'));
Router::addRoute('userChangeEq', 'user/ajaxChangeEq/:idProduct', array('controller'=>'UserController', 'method'=>'ajaxChangeEq'));

Router::addRoute('userRemoveFromMyEq', 'user/ajaxRemFromEq/:idProduct', array('controller'=>'UserController', 'method'=>'ajaxRemFromEq'));
Router::addRoute('userPointsDetails', 'user/points/:idUser', array('controller'=>'ProfileController', 'method'=>'points'));



Router::addRoute('getPhotoCropperAction', 'photo-cropper/:type/:action', array('controller'=>'ServerController', 'method' => 'PhotoCropper'));
Router::addRoute('uploadAvatar', 'photo-cropper/:type', array('controller'=>'ServerController', 'method' => 'PhotoCropper'));
Router::addRoute('profileValidation', 'validateprofile', array('controller'=>'UserController', 'method' => 'AjaxValidateEditprofile', 'config' => array('render' => 'validator')));
Router::addRoute('editProfile', 'profile', array('controller'=>'UserController', 'method' => 'Editprofile'));
Router::addRoute('newConnect', 'user/newconnect/:idUser', array('controller'=>'UserController', 'method'=>'AddConnect'));
Router::addRoute('removeConnect', 'user/removeconnect/:idUser', array('controller'=>'UserController', 'method'=>'RemoveConnect'));
Router::addRoute('newMessage', 'user/newmessage/:idUser', array('controller'=>'UserController', 'method'=>'AddMessage'));
Router::addRoute('messages', 'user/messages/index', array('controller'=>'UserController', 'method'=>'Messages'));
Router::addRoute('messagesThread', 'user/messages/thread/:threadId', array('controller'=>'UserController', 'method'=>'Messages'));
Router::addRoute('userProfile', 'user/:idUser', array('controller'=>'ProfileController', 'method'=>'ProfileView'));



//Landing page
Router::addRoute('landingPageIndexValidation', 'landingpage,aa,index,validation', array('controller'=>'LandingpageController', 'method'=>'IndexValidation', 'config' => array('render' => 'validator')));
Router::addRoute('landingPageIndex', 'landingpage/index', array('controller'=>'LandingpageController', 'method'=>'Index'));

Router::addRoute('landingPagePassion', 'landingpage/passion', array('controller'=>'LandingpageController', 'method'=>'Passion'));
Router::addRoute('landingPagePhilosophy', 'landingpage/philosophy', array('controller'=>'LandingpageController', 'method'=>'Philosophy'));
Router::addRoute('landingPageServices', 'landingpage/services', array('controller'=>'LandingpageController', 'method'=>'Services'));



// search
Router::AddRoute('extSearch', 'search/:query/page/:page/t/:t/v/:v/o/:o', array('controller' => 'SearchController', 'action'=>'Index'));
Router::AddRoute('mainSearch', 'search', array('controller' => 'SearchController', 'action'=>'Index'));

// przełączenie widoku strony
Router::AddRoute('ajaxSwitchPropertiesCounter', "switch-properties-counter", array('controller'=>'CategoryController', 'method'=>'AjaxSwitchPropertiesCounter'));
Router::addRoute('optCategoryView', ":categoryKey/:subCategoryKey/page/:page/t/:t/v/:v/o/:o", array('controller'=>'CategoryController', 'method'=>'View', 'paramMatrix' => array('options'=>'')));

/*
 * produkty
 */

//kometarze
Router::addRoute('subComment', "subComment", array('controller'=>'ProductController', 'method'=>'ajaxAddComment'));
Router::addRoute('rateComment', "rateComment/ajax/:action/:id", array('controller'=>'ProductController', 'method'=>'ajaxRateComment'));
Router::addRoute('filterComment', "commentFilter/ajax/:id", array('controller'=>'ProductController', 'method'=>'ajaxFilterComment'));
Router::addRoute('reportAbuse', "comment/abuse/ajax/:id", array('controller'=>'ProductController', 'method'=>'ajaxReportAbuseComment'));
Router::addRoute('saveReportAbuse', "comment/save/abuse/ajax/:id", array('controller'=>'ProductController', 'method'=>'ajaxSaveAbuseComment'));
Router::addRoute('SaveNewComment', "saveNewComment", array('controller'=>'ProductController', 'method'=>'SaveComment'));


Router::addRoute('opinionValidation', 'comment,write,validation', array('controller'=>'ProductController', 'method'=>'OpinionValidation', 'config' => array('render' => 'validator')));


//Router::addRoute('productComparePdf',   "compare/pdf/:categoryKey/:subCategoryKey/:productKey", array('controller'=>'PdfController', 'method'=>'ProductComparison'));
Router::addRoute('productComparePdf',   "pdf/compareproducts/:subCategoryKey/:listOfProducts", array('controller'=>'PdfController', 'method'=>'ProductComparison'));
Router::addRoute('productPdf',		"pdf/:categoryKey/:subCategoryKey/:productKey", array('controller'=>'PdfController', 'method'=>'ProductDetails'));

//Router::addRoute('productPdf', "pdf", array('controller'=>'PdfController', 'method'=>'ProductDetails'));
Router::addRoute('emptyMyList', "emptymylisty", array('controller'=>'ProductController', 'method'=>'EmptyMyList'));
Router::addRoute('productAddToCompare', "compare/:categoryKey/:subCategoryKey/:productKey", array('controller'=>'ProductController', 'method'=>'AddToCompare'));
Router::addRoute('productCompare', "compareproducts/:subCategoryKey/:listOfProducts", array('controller'=>'ProductController', 'method'=>'Compare'));
Router::addRoute('productView', ":categoryKey/:subCategoryKey/:productKey", array('controller'=>'ProductController', 'method'=>'View'));



/* 
 * kategorie
 */

Router::addRoute('mainCategoryView', ":categoryKey/:subCategoryKey", array('controller'=>'CategoryController', 'method'=>'View', 'paramMatrix' => array('options'=>'')));



/*
 * logowane i wylogowanie
 */
Router::AddRoute('login', 'log-in', array('controller'=>'AuthController', 'method'=>'Login'));
Router::AddRoute('logout', 'log-out', array('controller'=>'AuthController', 'method'=>'Logout'));

/*
 * wall
 */
Router::AddRoute('wallLoadWall','load_wall', array('controller' => 'WallController', 'method' => 'LoadWall', 'config' => array('render' => 'ajax')));
Router::AddRoute('wallPostWall','post_wall', array('controller' => 'WallController', 'method' => 'PostWall', 'config' => array('render' => 'ajax')));
Router::AddRoute('wallUpload','attach_wall',array('controller' => 'WallController', 'method' => 'Upload'));
Router::AddRoute('wallIndex','wall',array('controller' => 'WallController', 'method' => 'Index', 'config' => array('menu_tab' => 'wall')));

/*
 * index
 */
Router::AddRoute('default', 'index', array('controller'=>'IndexController', 'method'=>'Index'));

//Router::AddRoute('test', "(/test/:atest/:testa/)", array('controller'=>'IndexController', 'method'=>'Index', 'paramMatrix'=>array(''atest'=>'')));
